<!DOCTYPE html>
<html lang="zh-CN">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no">
    <title>添加药品</title>
    <script src="https://cdn.tailwindcss.com"></script>
    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
    <style>
        * {
            margin: 0;
            padding: 0;
            box-sizing: border-box;
        }

        body {
            font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
            background: linear-gradient(135deg, #E8EAF6 0%, #F3E5F5 50%, #FCE4EC 100%);
            min-height: 100vh;
        }

        .glass-card {
            background: rgba(255, 255, 255, 0.95);
            backdrop-filter: blur(20px);
            border: 1px solid rgba(255, 255, 255, 0.3);
        }

        .input-field {
            transition: all 0.3s;
        }

        .input-field:focus {
            transform: translateY(-2px);
        }

        @keyframes pulse {

            0%,
            100% {
                opacity: 1;
            }

            50% {
                opacity: 0.6;
            }
        }

        .animate-pulse-slow {
            animation: pulse 2s ease-in-out infinite;
        }

        /* 手机状态栏占位 */
        .status-bar-spacer {
            height: 28px;
            background: rgba(255, 255, 255, 0.95);
            backdrop-filter: blur(20px);
            position: relative;
            z-index: 999;
        }
    </style>
</head>

<body>
    <!-- 手机状态栏占位 -->
    <div class="status-bar-spacer"></div>

    <div class="min-h-screen pb-24">
        <!-- 顶部导航 -->
        <div class="glass-card px-5 py-4">
            <div class="flex items-center justify-between">
                <button onclick="history.back()"
                    class="w-10 h-10 bg-white rounded-xl flex items-center justify-center shadow-sm">
                    <i class="fas fa-arrow-left text-gray-700"></i>
                </button>
                <h1 class="text-lg font-bold text-gray-900">添加药品</h1>
                <button
                    class="px-4 py-2 bg-black text-white rounded-xl text-sm font-semibold shadow-lg hover:scale-105 transition-transform">
                    保存
                </button>
            </div>
        </div>

        <!-- 便捷录入方式 -->
        <div class="px-5 py-6">
            <div class="flex items-center gap-2 mb-4">
                <div
                    class="w-8 h-8 bg-gradient-to-br from-blue-500 to-purple-500 rounded-xl flex items-center justify-center">
                    <i class="fas fa-bolt text-white text-sm"></i>
                </div>
                <span class="font-bold text-gray-900">便捷录入</span>
            </div>

            <div class="grid grid-cols-3 gap-3">
                <button
                    class="glass-card rounded-3xl p-5 shadow-lg hover:shadow-xl transition-all hover:scale-105 active:scale-95">
                    <div
                        class="w-14 h-14 mx-auto mb-3 bg-gradient-to-br from-blue-400 to-indigo-500 rounded-2xl flex items-center justify-center shadow-lg">
                        <i class="fas fa-qrcode text-white text-2xl"></i>
                    </div>
                    <div class="text-sm font-semibold text-gray-900 text-center">扫码录入</div>
                    <div class="text-xs text-gray-500 text-center mt-1">快速扫描</div>
                </button>

                <button
                    class="glass-card rounded-3xl p-5 shadow-lg hover:shadow-xl transition-all hover:scale-105 active:scale-95">
                    <div
                        class="w-14 h-14 mx-auto mb-3 bg-gradient-to-br from-pink-400 to-rose-500 rounded-2xl flex items-center justify-center shadow-lg">
                        <i class="fas fa-camera text-white text-2xl"></i>
                    </div>
                    <div class="text-sm font-semibold text-gray-900 text-center">拍照录入</div>
                    <div class="text-xs text-gray-500 text-center mt-1">识别说明书</div>
                </button>

                <button
                    class="glass-card rounded-3xl p-5 shadow-lg hover:shadow-xl transition-all hover:scale-105 active:scale-95">
                    <div
                        class="w-14 h-14 mx-auto mb-3 bg-gradient-to-br from-purple-400 to-violet-500 rounded-2xl flex items-center justify-center shadow-lg">
                        <i class="fas fa-history text-white text-2xl"></i>
                    </div>
                    <div class="text-sm font-semibold text-gray-900 text-center">历史记录</div>
                    <div class="text-xs text-gray-500 text-center mt-1">常用药品</div>
                </button>
            </div>
        </div>

        <!-- 基本信息 -->
        <div class="px-5 mb-6">
            <div class="glass-card rounded-3xl p-5 shadow-lg">
                <div class="flex items-center gap-2 mb-5">
                    <div
                        class="w-8 h-8 bg-gradient-to-br from-green-500 to-emerald-500 rounded-xl flex items-center justify-center">
                        <i class="fas fa-pills text-white text-sm"></i>
                    </div>
                    <span class="font-bold text-gray-900">基本信息</span>
                </div>

                <div class="space-y-4">
                    <div>
                        <label class="block text-sm font-semibold text-gray-700 mb-2">药品通用名称 *</label>
                        <input type="text" placeholder="请输入药品通用名称"
                            class="input-field w-full px-4 py-3.5 bg-gray-50 border-2 border-gray-100 rounded-2xl text-sm focus:outline-none focus:border-purple-300 focus:bg-white transition-all">
                    </div>

                    <div>
                        <label class="block text-sm font-semibold text-gray-700 mb-2">药品商品名称</label>
                        <input type="text" placeholder="如：泰诺林、康泰克等"
                            class="input-field w-full px-4 py-3.5 bg-gray-50 border-2 border-gray-100 rounded-2xl text-sm focus:outline-none focus:border-purple-300 focus:bg-white transition-all">
                    </div>

                    <div class="grid grid-cols-2 gap-3">
                        <div>
                            <label class="block text-sm font-semibold text-gray-700 mb-2">规格</label>
                            <input type="text" placeholder="如：0.3g"
                                class="input-field w-full px-4 py-3.5 bg-gray-50 border-2 border-gray-100 rounded-2xl text-sm focus:outline-none focus:border-purple-300 focus:bg-white transition-all">
                        </div>
                        <div>
                            <label class="block text-sm font-semibold text-gray-700 mb-2">数量</label>
                            <input type="number" placeholder="如：20"
                                class="input-field w-full px-4 py-3.5 bg-gray-50 border-2 border-gray-100 rounded-2xl text-sm focus:outline-none focus:border-purple-300 focus:bg-white transition-all">
                        </div>
                    </div>

                    <div>
                        <label class="block text-sm font-semibold text-gray-700 mb-2">药品分类</label>
                        <select
                            class="input-field w-full px-4 py-3.5 bg-gray-50 border-2 border-gray-100 rounded-2xl text-sm focus:outline-none focus:border-purple-300 focus:bg-white transition-all">
                            <option>请选择药品分类</option>
                            <option>解热镇痛药</option>
                            <option>抗生素</option>
                            <option>感冒药</option>
                            <option>消化系统用药</option>
                            <option>心血管药物</option>
                            <option>保健品</option>
                            <option>外用药</option>
                        </select>
                    </div>

                    <div>
                        <label class="block text-sm font-semibold text-gray-700 mb-2">适应症</label>
                        <textarea placeholder="请输入适应症..." rows="3"
                            class="input-field w-full px-4 py-3.5 bg-gray-50 border-2 border-gray-100 rounded-2xl text-sm focus:outline-none focus:border-purple-300 focus:bg-white transition-all resize-none"></textarea>
                    </div>
                </div>
            </div>
        </div>

        <!-- 库存信息 -->
        <div class="px-5 mb-6">
            <div class="glass-card rounded-3xl p-5 shadow-lg">
                <div class="flex items-center gap-2 mb-5">
                    <div
                        class="w-8 h-8 bg-gradient-to-br from-orange-500 to-amber-500 rounded-xl flex items-center justify-center">
                        <i class="fas fa-box text-white text-sm"></i>
                    </div>
                    <span class="font-bold text-gray-900">库存信息</span>
                </div>

                <div class="space-y-4">
                    <div class="grid grid-cols-2 gap-3">
                        <div>
                            <label class="block text-sm font-semibold text-gray-700 mb-2">当前库存 *</label>
                            <div class="relative">
                                <input type="number" placeholder="0" value="20"
                                    class="input-field w-full px-4 py-3.5 bg-gray-50 border-2 border-gray-100 rounded-2xl text-sm focus:outline-none focus:border-purple-300 focus:bg-white transition-all">
                                <span class="absolute right-4 top-1/2 -translate-y-1/2 text-gray-400 text-sm">粒</span>
                            </div>
                        </div>
                        <div>
                            <label class="block text-sm font-semibold text-gray-700 mb-2">低库存提醒</label>
                            <div class="relative">
                                <input type="number" placeholder="0" value="5"
                                    class="input-field w-full px-4 py-3.5 bg-gray-50 border-2 border-gray-100 rounded-2xl text-sm focus:outline-none focus:border-purple-300 focus:bg-white transition-all">
                                <span class="absolute right-4 top-1/2 -translate-y-1/2 text-gray-400 text-sm">粒</span>
                            </div>
                        </div>
                    </div>

                    <div>
                        <label class="block text-sm font-semibold text-gray-700 mb-2">生产日期</label>
                        <input type="date"
                            class="input-field w-full px-4 py-3.5 bg-gray-50 border-2 border-gray-100 rounded-2xl text-sm focus:outline-none focus:border-purple-300 focus:bg-white transition-all">
                    </div>

                    <div>
                        <label class="block text-sm font-semibold text-gray-700 mb-2">有效期至 *</label>
                        <input type="date"
                            class="input-field w-full px-4 py-3.5 bg-gray-50 border-2 border-gray-100 rounded-2xl text-sm focus:outline-none focus:border-purple-300 focus:bg-white transition-all">
                    </div>

                    <div>
                        <label class="block text-sm font-semibold text-gray-700 mb-2">存储位置</label>
                        <input type="text" placeholder="如：客厅抽屉、主卧柜子"
                            class="input-field w-full px-4 py-3.5 bg-gray-50 border-2 border-gray-100 rounded-2xl text-sm focus:outline-none focus:border-purple-300 focus:bg-white transition-all">
                    </div>
                </div>
            </div>
        </div>

        <!-- 补充信息 -->
        <div class="px-5 mb-6">
            <div class="glass-card rounded-3xl p-5 shadow-lg">
                <div class="flex items-center gap-2 mb-5">
                    <div
                        class="w-8 h-8 bg-gradient-to-br from-purple-500 to-pink-500 rounded-xl flex items-center justify-center">
                        <i class="fas fa-info-circle text-white text-sm"></i>
                    </div>
                    <span class="font-bold text-gray-900">补充信息</span>
                </div>

                <div class="space-y-4">
                    <div>
                        <label class="block text-sm font-semibold text-gray-700 mb-2">用法用量</label>
                        <textarea placeholder="如：每次1-2粒，每日3次，餐后服用" rows="2"
                            class="input-field w-full px-4 py-3.5 bg-gray-50 border-2 border-gray-100 rounded-2xl text-sm focus:outline-none focus:border-purple-300 focus:bg-white transition-all resize-none"></textarea>
                    </div>

                    <div>
                        <label class="block text-sm font-semibold text-gray-700 mb-2">注意事项</label>
                        <textarea placeholder="如：孕妇慎用、不宜与某某药同服" rows="2"
                            class="input-field w-full px-4 py-3.5 bg-gray-50 border-2 border-gray-100 rounded-2xl text-sm focus:outline-none focus:border-purple-300 focus:bg-white transition-all resize-none"></textarea>
                    </div>

                    <div class="flex items-center justify-between py-2">
                        <div>
                            <div class="font-semibold text-gray-900 text-sm">设为常用药</div>
                            <div class="text-xs text-gray-500 mt-0.5">加入常用药清单</div>
                        </div>
                        <label class="relative inline-block w-12 h-7">
                            <input type="checkbox" class="sr-only peer">
                            <div
                                class="w-12 h-7 bg-gray-200 rounded-full peer peer-checked:bg-gradient-to-r peer-checked:from-purple-500 peer-checked:to-pink-500 transition-all">
                            </div>
                            <div
                                class="absolute left-1 top-1 w-5 h-5 bg-white rounded-full shadow-md transition-transform peer-checked:translate-x-5">
                            </div>
                        </label>
                    </div>
                </div>
            </div>
        </div>

        <!-- 提交按钮区 -->
        <div class="px-5 pb-6">
            <button
                class="w-full py-4 bg-gradient-to-r from-purple-500 to-pink-500 text-white rounded-2xl font-bold text-lg shadow-xl hover:shadow-2xl hover:scale-105 transition-all">
                ✅ 保存药品信息
            </button>
        </div>
    </div>

    <!-- 底部导航 -->
    <div class="fixed bottom-0 left-0 right-0 glass-card px-5 py-3 border-t border-gray-100">
        <div class="flex items-center justify-around">
            <a href="index.html" class="flex flex-col items-center gap-1 text-gray-400">
                <div class="w-12 h-12 bg-white rounded-2xl flex items-center justify-center shadow-sm">
                    <i class="fas fa-home"></i>
                </div>
                <span class="text-xs font-medium">首页</span>
            </a>
            <a href="medicine_management.html" class="flex flex-col items-center gap-1 text-gray-400">
                <div class="w-12 h-12 bg-white rounded-2xl flex items-center justify-center shadow-sm">
                    <i class="fas fa-pills"></i>
                </div>
                <span class="text-xs font-medium">药品</span>
            </a>
            <a href="add_medicine.html" class="flex flex-col items-center gap-1 text-purple-600">
                <div
                    class="w-12 h-12 bg-gradient-to-br from-purple-500 to-pink-500 rounded-2xl flex items-center justify-center shadow-lg">
                    <i class="fas fa-plus-circle text-white"></i>
                </div>
                <span class="text-xs font-semibold">添加</span>
            </a>
            <a href="reminder.html" class="flex flex-col items-center gap-1 text-gray-400">
                <div class="w-12 h-12 bg-white rounded-2xl flex items-center justify-center shadow-sm">
                    <i class="fas fa-bell"></i>
                </div>
                <span class="text-xs font-medium">提醒</span>
            </a>
            <a href="profile.html" class="flex flex-col items-center gap-1 text-gray-400">
                <div class="w-12 h-12 bg-white rounded-2xl flex items-center justify-center shadow-sm">
                    <i class="fas fa-user"></i>
                </div>
                <span class="text-xs font-medium">我的</span>
            </a>
        </div>
    </div>
</body>

</html>